using XNgine.Misc;

namespace XNgine.DebugConsole.Commands
{
    public abstract class Command : INamedItem
    {
        /// <summary>
        /// The string that will identify the command
        /// (user will use this string to invoke the command from the console)
        /// </summary>
        public abstract string Name { get; }

        public abstract CommandResult Execute(object[] args);
        public CommandResult Execute(string args)
        {
            return Execute(InterpretArgs(args));
        }

        private object[] InterpretArgs(string args)
        {
            // TODO: Replace the mock with real args
            return new object[0];
        }
    }
}